<?php /* Smarty version 2.6.12, created on 2008-10-30 14:55:58
         compiled from admin/main/countries.tpl */ ?>
<?php require_once(SMARTY_CORE_DIR . 'core.load_plugins.php');
smarty_core_load_plugins(array('plugins' => array(array('function', 'cycle', 'admin/main/countries.tpl', 44, false),array('modifier', 'strip_tags', 'admin/main/countries.tpl', 57, false),array('modifier', 'escape', 'admin/main/countries.tpl', 57, false),)), $this); ?>
<?php func_load_lang($this, "admin/main/countries.tpl","lbl_countries_management,txt_countries_management_top_text,lbl_code,lbl_country,lbl_has_states,lbl_active,lbl_update,lbl_deactivate_all,lbl_activate_all,lbl_countries"); ?>
<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "page_title.tpl", 'smarty_include_vars' => array('title' => $this->_tpl_vars['lng']['lbl_countries_management'])));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>

<?php echo $this->_tpl_vars['lng']['txt_countries_management_top_text']; ?>


<br /><br />

<?php ob_start(); ?>

<?php unset($this->_sections['zone']);
$this->_sections['zone']['name'] = 'zone';
$this->_sections['zone']['loop'] = is_array($_loop=$this->_tpl_vars['zones']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['zone']['show'] = true;
$this->_sections['zone']['max'] = $this->_sections['zone']['loop'];
$this->_sections['zone']['step'] = 1;
$this->_sections['zone']['start'] = $this->_sections['zone']['step'] > 0 ? 0 : $this->_sections['zone']['loop']-1;
if ($this->_sections['zone']['show']) {
    $this->_sections['zone']['total'] = $this->_sections['zone']['loop'];
    if ($this->_sections['zone']['total'] == 0)
        $this->_sections['zone']['show'] = false;
} else
    $this->_sections['zone']['total'] = 0;
if ($this->_sections['zone']['show']):

            for ($this->_sections['zone']['index'] = $this->_sections['zone']['start'], $this->_sections['zone']['iteration'] = 1;
                 $this->_sections['zone']['iteration'] <= $this->_sections['zone']['total'];
                 $this->_sections['zone']['index'] += $this->_sections['zone']['step'], $this->_sections['zone']['iteration']++):
$this->_sections['zone']['rownum'] = $this->_sections['zone']['iteration'];
$this->_sections['zone']['index_prev'] = $this->_sections['zone']['index'] - $this->_sections['zone']['step'];
$this->_sections['zone']['index_next'] = $this->_sections['zone']['index'] + $this->_sections['zone']['step'];
$this->_sections['zone']['first']      = ($this->_sections['zone']['iteration'] == 1);
$this->_sections['zone']['last']       = ($this->_sections['zone']['iteration'] == $this->_sections['zone']['total']);
?>
<span style="white-space: nowrap; padding-right: 20px;">
<?php if ($this->_tpl_vars['zones'][$this->_sections['zone']['index']]['zone'] == $this->_tpl_vars['zone'] || ( $this->_tpl_vars['zones'][$this->_sections['zone']['index']]['zone'] == 'ALL' && $this->_tpl_vars['zone'] == "" )): ?>
<b><?php echo $this->_tpl_vars['zones'][$this->_sections['zone']['index']]['title']; ?>
</b>
<?php else: ?>
<a href="countries.php<?php if ($this->_tpl_vars['zones'][$this->_sections['zone']['index']]['zone']): ?>?zone=<?php echo $this->_tpl_vars['zones'][$this->_sections['zone']['index']]['zone'];  endif; ?>"><?php echo $this->_tpl_vars['zones'][$this->_sections['zone']['index']]['title']; ?>
</a>
<?php endif; ?>
</span>
 &nbsp; 
<?php endfor; endif; ?>

<br /><br />

<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "customer/main/navigation.tpl", 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>

<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "main/check_all_row.tpl", 'smarty_include_vars' => array('style' => "line-height: 170%; text-align: right;",'form' => 'editcountriesform','prefix' => "posted_data.+active")));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>

<form action="countries.php" method="post" name="editcountriesform">
<input type="hidden" name="mode" value="" />
<input type="hidden" name="page" value="<?php echo $GLOBALS['HTTP_GET_VARS']['page']; ?>
" />
<input type="hidden" name="zone" value="<?php echo $this->_tpl_vars['zone']; ?>
" />

<table cellpadding="2" cellspacing="1" width="100%">

<tr class="TableHead">
	<td nowrap="nowrap"><?php echo $this->_tpl_vars['lng']['lbl_code']; ?>
</td>
	<td width="80%" nowrap="nowrap"><?php echo $this->_tpl_vars['lng']['lbl_country']; ?>
</td>
	<td width="10%" nowrap="nowrap"><?php echo $this->_tpl_vars['lng']['lbl_has_states']; ?>
</td>
	<td nowrap="nowrap"><?php echo $this->_tpl_vars['lng']['lbl_active']; ?>
</td>
</tr>

<?php unset($this->_sections['country']);
$this->_sections['country']['name'] = 'country';
$this->_sections['country']['loop'] = is_array($_loop=$this->_tpl_vars['countries']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['country']['show'] = true;
$this->_sections['country']['max'] = $this->_sections['country']['loop'];
$this->_sections['country']['step'] = 1;
$this->_sections['country']['start'] = $this->_sections['country']['step'] > 0 ? 0 : $this->_sections['country']['loop']-1;
if ($this->_sections['country']['show']) {
    $this->_sections['country']['total'] = $this->_sections['country']['loop'];
    if ($this->_sections['country']['total'] == 0)
        $this->_sections['country']['show'] = false;
} else
    $this->_sections['country']['total'] = 0;
if ($this->_sections['country']['show']):

            for ($this->_sections['country']['index'] = $this->_sections['country']['start'], $this->_sections['country']['iteration'] = 1;
                 $this->_sections['country']['iteration'] <= $this->_sections['country']['total'];
                 $this->_sections['country']['index'] += $this->_sections['country']['step'], $this->_sections['country']['iteration']++):
$this->_sections['country']['rownum'] = $this->_sections['country']['iteration'];
$this->_sections['country']['index_prev'] = $this->_sections['country']['index'] - $this->_sections['country']['step'];
$this->_sections['country']['index_next'] = $this->_sections['country']['index'] + $this->_sections['country']['step'];
$this->_sections['country']['first']      = ($this->_sections['country']['iteration'] == 1);
$this->_sections['country']['last']       = ($this->_sections['country']['iteration'] == $this->_sections['country']['total']);
?>

<tr<?php if ($this->_tpl_vars['countries'][$this->_sections['country']['index']]['code'] == $this->_tpl_vars['config']['Company']['location_country']): ?> class="TableHead"<?php else:  echo smarty_function_cycle(array('values' => ', class="TableSubHead"'), $this); endif; ?>>
	<td nowrap="nowrap" align="center"><?php echo $this->_tpl_vars['countries'][$this->_sections['country']['index']]['code']; ?>
</td>
	<td><input type="text" size="34" maxlength="50" name="posted_data[<?php echo $this->_tpl_vars['countries'][$this->_sections['country']['index']]['code']; ?>
][country]" value="<?php echo $this->_tpl_vars['countries'][$this->_sections['country']['index']]['country']; ?>
" style="width: 99%;" /></td>
	<td align="center"><input type="checkbox" name="posted_data[<?php echo $this->_tpl_vars['countries'][$this->_sections['country']['index']]['code']; ?>
][display_states]" value="Y"<?php if ($this->_tpl_vars['countries'][$this->_sections['country']['index']]['display_states'] == 'Y'): ?> checked="checked"<?php endif; ?> /></td>
	<td align="center"><input type="checkbox" name="posted_data[<?php echo $this->_tpl_vars['countries'][$this->_sections['country']['index']]['code']; ?>
][active]" value="Y"<?php if ($this->_tpl_vars['countries'][$this->_sections['country']['index']]['active'] == 'Y'): ?> checked="checked"<?php endif; ?> /></td>
</tr>
<?php endfor; endif; ?>

<tr>
<td colspan="5"><br />

<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "customer/main/navigation.tpl", 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>

<input type="submit" value="<?php echo ((is_array($_tmp=((is_array($_tmp=$this->_tpl_vars['lng']['lbl_update'])) ? $this->_run_mod_handler('strip_tags', true, $_tmp, false) : smarty_modifier_strip_tags($_tmp, false)))) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
" />
<br /><br />
<input type="button" value="<?php echo ((is_array($_tmp=((is_array($_tmp=$this->_tpl_vars['lng']['lbl_deactivate_all'])) ? $this->_run_mod_handler('strip_tags', true, $_tmp, false) : smarty_modifier_strip_tags($_tmp, false)))) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
" onclick="javascript: document.editcountriesform.mode.value = 'deactivate_all'; document.editcountriesform.submit();" />
&nbsp;&nbsp;&nbsp;&nbsp;
<input type="button" value="<?php echo ((is_array($_tmp=((is_array($_tmp=$this->_tpl_vars['lng']['lbl_activate_all'])) ? $this->_run_mod_handler('strip_tags', true, $_tmp, false) : smarty_modifier_strip_tags($_tmp, false)))) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
" onclick="javascript: document.editcountriesform.mode.value = 'activate_all'; document.editcountriesform.submit();" />
</td>
</tr>

</table>
</form>

<br /><br />

<?php $this->_smarty_vars['capture']['dialog'] = ob_get_contents(); ob_end_clean();  $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "dialog.tpl", 'smarty_include_vars' => array('title' => $this->_tpl_vars['lng']['lbl_countries'],'content' => $this->_smarty_vars['capture']['dialog'],'extra' => 'width="100%"')));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>